﻿
module ExtentionTest

type Variant =
    | Num of int
    | Str of string

// Add a member to Variant as an extension
type Variant with
    member x.Print() =
        match x with
        | Num n -> printf "Num %d" n
        | Str s -> printf "Str %s" s
